/* 
 * File:   MathEdit.h
 * Author: user
 *
 * Created on December 10, 2012, 3:12 PM
 */

#ifndef MATHEDIT_H
#define	MATHEDIT_H

#include <QTextEdit>
#include "Highlighter.h"

using namespace std;

class MathEdit : public QTextEdit {
    Q_OBJECT

public:
    MathEdit(const QPoint &pos, QWidget * parent = 0);
    MathEdit(const MathEdit& orig) = delete;
    virtual ~MathEdit() = default;

private slots:

protected:
    void focusOutEvent(QFocusEvent * event);
    void keyPressEvent(QKeyEvent *event);
    QSize sizeHint() const;

private:
    Highlighter* highlighter;

};

#endif	/* MATHEDIT_H */

